import { Routes, Route, Navigate } from 'react-router-dom';
import List from "../pages/List";
import Detail from "../pages/Detail";

const AppRoutes = () => {
  return (
    <Routes>
      <Route path="/" exact element={<Navigate to="/list" replace />} />
      <Route path="/list" exact Component={List} />
      <Route path="/detail/:id" exact Component={Detail} />
    </Routes>
  );
};

export default AppRoutes;